
public class CostedPath {
	public MazeNodes path;
	public MazeEdges edges;
	public static int startFQ;
	
	public CostedPath(MazeNodes path, MazeEdges edges) {
		this.path = path;
		this.edges = edges;
	}
	
	public int getFq() {
		int fq = startFQ; // We treat the start node as a food node only when at the beginning of the search
		
		for (MazeNode node : this.path) {
			//if(node.getType() != MazeNode.Type.START)
				fq += node.getFood_gain() - node.getFood_consume();
		}
		for (MazeEdge edge : this.edges) {
			fq -= edge.getCost(); 
		}
		
		return fq;
	}
	
	public int getCost() {
		int cost = 0; 
		
		for (MazeNode node : this.path) {
			cost += node.getFood_consume();
		}
		for (MazeEdge edge : this.edges) {
			cost += edge.getCost(); 
		}
		
		return cost;
	}
}